<template>
	<uni-list class="container">
		<uni-list-item v-for="(item, index) in 10" :key="index">
			<template v-slot:body>
				<view class="content" @click="handleClick">
					<view class="left">
						<view class="top">
							“剩饭剩菜不怕坏，多加热就好了”？看完赶紧转给家人！
						</view>
						<view class="bottom">
							<text class="text">热搜</text>
							<uni-dateformat date="2020/10/20 20:20:20"></uni-dateformat>
						</view>
					</view>
					<view class="right">
						<image class="image" src="/common/new1.jpg" mode="aspectFill"></image>
					</view>
				</view>
			</template>
		</uni-list-item>
	</uni-list>
</template>

<script setup>
	function handleClick(){
		console.log(111)
		uni.navigateTo({
			url: "/pages/new-info/new-info"
		})
	}


</script>

<style lang="scss" scoped>
	.container {
		.content {
			width: 100%;
			height: 150rpx;
			padding: 35rpx 0;
			display: flex;

			.left {
				flex: 4;
				margin-right: 20rpx;
				
				.top{
					font-size: 35rpx;
				}
				.bottom{
					font-size: 25rpx;
					margin-top: 30rpx;
					.text{
						margin-right: 30rpx;
					}
				}
			}

			.right {
				flex: 1;
				height: 100%;

				.image {
					width: 100%;
					height: 100%;
				}
			}
		}
	}
</style>